package com.cq.hd.member.api.vo;

import com.alibaba.fastjson.annotation.JSONField;
import com.cq.hd.common.serialize.Decimal2Serializer;
import com.fasterxml.jackson.annotation.JsonFormat;


import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;

@Data
public class AgentPageVo implements Serializable {

    @ApiModelProperty(value = "用户id")
    private Long id;

    @ApiModelProperty(value = "汇付id，有这个id，表示已经签约")
    private String hfId;

    @ApiModelProperty(value = "真实姓名")
    private String realName;

    @ApiModelProperty(value = "昵称")
    private String nickName;

    @ApiModelProperty(value = "头像")
    private String avatar;

    @ApiModelProperty(value = "手机号")
    private String mobile;

    @ApiModelProperty(value = "佣金账户余额")
    @JsonSerialize(using = Decimal2Serializer.class)
    private BigDecimal commissionAmt;

    @ApiModelProperty(value = "总分销订单数")
    private Integer totalOrderCount = 0;

    @ApiModelProperty(value = "总分销订单金额")
    @JsonSerialize(using = Decimal2Serializer.class)
    private BigDecimal totalOrderAmt = BigDecimal.ZERO;

    @ApiModelProperty(value = "关联策划人数")
    private Integer relationBusinessCount = 0;

    @ApiModelProperty(value = "累计分销佣金")
    @JsonSerialize(using = Decimal2Serializer.class)
    private BigDecimal totalCommission = BigDecimal.ZERO;

    @ApiModelProperty(value = "累计提现佣金")
    @JsonSerialize(using = Decimal2Serializer.class)
    private BigDecimal totalWithdrawalCommission = BigDecimal.ZERO;

    @ApiModelProperty(value = "经纪人入驻时间")
    @JSONField(format="yyyy.MM.dd HH:mm:ss")
    private LocalDateTime enterTime;

    @ApiModelProperty(value = "邀请码")
    private String inviteCode;

    @ApiModelProperty(value = "上级经纪人")
    private Long agentId;

    @ApiModelProperty(value = "上级经纪人昵称")
    private String agentNickName;

    @ApiModelProperty(value = "上级经纪人手机号")
    private String agentMobile;

    @ApiModelProperty(value = "经纪人等级：0不是经纪人 1一级经纪人 2二级经纪人")
    private Integer agentLevel = 0;
}
